﻿@model ViewDataBusiness.ViewSetting
@{
    ViewBag.Title = Model.ViewTitle;

    ViewBag.jQuery = true;
    ViewBag.jQueryUI = true;
    ViewBag.Json = true;
    ViewBag.Global = true;
    ViewBag.CKEditor = true;
    ViewBag.CKFinder = true;
    ViewBag.Uploadify = true;

    ViewBag.Css = "/Content/ViewSetting/Site.css";
    ViewBag.Js = "/Content/" + ViewContext.RouteData.Values["ViewForder"] + "/" + ViewContext.RouteData.Values["ViewName"] + ".js";
    
    Layout = "~/Views/_Template.cshtml";

    Session["CKFinder"] = DateTime.Now;
    Session["CKFinder_BaseUrl"] = "/UpFiles/WebSite/";

    Dictionary<string, object> Info = (Dictionary<string, object>)((List<object>)Model.Operations["浏览产品资料"].OperationData)[0];
}      
<script type="text/javascript">var JsonOriginal = @Html.Raw(Model.JsonString);</script> 
<script type="text/javascript">var WebButtonList = @Html.Raw(Info["web_button_list"].ToString() == "" ? "{}" : Info["web_button_list"].ToString());</script> 
<table id="MainTable" cellpadding="0" cellspacing="4">
    <tr><td class="PageTitle"><div class="Title">@Model.ViewTitle > @Info["pd_cn_name"]</div></td></tr>  
    <tr id="TabTR"><td class="TopTD"><div id="TabRadio"><input type="radio" id="radio1" name="TabRadio" value="基本信息" checked="checked" /><label for="radio1">基本信息</label><input type="radio" id="radio2" name="TabRadio" value="网站信息" /><label for="radio2">网站信息</label><input type="radio" id="radio3" name="TabRadio" value="产品图片" /><label for="radio3">产品图片</label><input type="radio" id="radio4" name="TabRadio" value="相关文档" /><label for="radio4">相关文档</label><input type="radio" id="radio5" name="TabRadio" value="相关链接" /><label for="radio5">相关链接</label></div></td></tr> 
    <tr id="TabTR1"><td class="Unit">
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">系统编号</td><td class="Input"><input type="text" value="@Info["voucher_id"]" title="@Info["voucher_id"]" readonly="readonly" style="width:100px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品货号</td><td class="Input"><input type="text" value="@Info["pd_id"]" title="@Info["pd_id"]" readonly="readonly" style="width:100px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品条码</td><td class="Input"><input type="text" value="@Info["bar_code"]" title="@Info["bar_code"]" readonly="readonly" style="width:120px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品名称</td><td class="Input"><input type="text" value="@Info["pd_cn_name"]" title="@Info["pd_cn_name"]" readonly="readonly" style="width:355px" /></td></tr></table></div>
        <div class="Clear"></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品单位</td><td class="Input"><input type="text" value="@Info["uom"]" title="@Info["uom"]" readonly="readonly" style="width:100px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品来源</td><td class="Input"><input type="text" value="@Info["Source"]" title="@Info["Source"]" readonly="readonly" style="width:100px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品分类</td><td class="Input"><input type="text" value="@Info["Type"]" title="@Info["Type"]" readonly="readonly" style="width:120px" /></td></tr></table></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品规格</td><td class="Input"><input type="text" value="@Info["pd_cn_spec"]" title="@Info["pd_cn_spec"]" readonly="readonly" style="width:355px" /></td></tr></table></div>
        <div class="Clear"></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">文字描述</td><td class="Input"><textarea id="text_description" style="width:900px;height:51px;">@Info["text_description"]</textarea></td></tr></table></div>
        <div class="Clear"></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">备　　注</td><td class="Input"><textarea id="remark" style="width:900px;height:51px;">@Info["remark"]</textarea></td></tr></table></div>
    </td></tr>
    <tr id="TabTR2" style="display:none"><td class="Unit">
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">搜索描述</td><td class="Input"><input type="text" id="web_desc" value="@Info["web_desc"]" title="@Info["web_desc"]" style="width:900px" /></td></tr></table></div>
        <div class="Clear"></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">关<span> </span>键<span> </span>字</td><td class="Input"><input id="web_keyword" type="text" value="@Info["web_keyword"]" title="@Info["web_keyword"]" style="width:900px" /></td></tr></table></div>
        <div class="Clear"></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品卖点</td><td class="Input"><input type="text" id="web_spec" value="@Info["web_spec"]" title="@Info["web_spec"]" style="width:900px" /></td></tr></table></div>
        <div class="Clear"></div>
        <div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">产品描述</td><td class="Input"><textarea id="web_description" style="width:900px;height:400px;">@Info["web_description"]</textarea></td></tr></table></div>
    </td></tr>     
    <tr id="TabTR3" style="display:none"><td class="Unit">
        <table border="0" cellpadding="0" cellspacing="0">
            <tr><td id="ImageDiv"></td></tr>
            <tr><td id="UploadImage_Panel" style="display:none"><input type="file" name="ImageUupload" id="ImageUpload" /></td></tr>
        </table>
    </td></tr>
    <tr id="TabTR4" style="display:none"><td class="Unit">
        <table border="0" cellpadding="0" cellspacing="0">
            <tr><td id="FileDiv"></td></tr>
            <tr><td id="UploadDoc_Panel" style="display:none"><input type="file" name="DocUpload" id="DocUpload" /></td></tr>
        </table>
    </td></tr>
    <tr id="TabTR5" style="display:none"><td class="Unit" id="LinkDiv"></td></tr>
    <tr><td class="ButtonUnit"><button id="ButtonSave">保存</button><button id="ButtonBack">返回</button></td></tr>   
</table>
<div id="ItemHTML" style="display:none">
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">类别</td><td class="Input"><input onblur="if(this.value!='' && $('#itemPanelID input[name=ItemType]:last').val()!=''){AddItem();}" class="Select" type="text" name="ItemType" style="width:100px" /></td></tr></table></div>
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">名称</td><td class="Input"><input type="text" name="ItemName" style="width:100px" /></td></tr></table></div>
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">地址</td><td class="Input"><input type="text" name="ItemValue" style="width:492px" /></td></tr></table></div>  
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">启用</td><td class="Input"><input type="checkbox" checked="checked" name="ItemEnable" /></td></tr></table></div>                           
<div class="AIcon"><div class="Icon ItemHandle" style="visibility:hidden;"><div style="cursor:move;" class="ui-state-default ui-corner-all" onmouseover="$(this).addClass('ui-state-hover');" onmouseout="$(this).removeClass('ui-state-hover');"><span class="ui-icon ui-icon-arrow-4-diag"></span></div></div></div>
<div class="AIcon"><div class="Icon" onclick="DeleteItem(this);" style="visibility:hidden;"><div class="ui-state-default ui-corner-all" onmouseover="$(this).addClass('ui-state-hover');" onmouseout="$(this).removeClass('ui-state-hover');"><span class="ui-icon ui-icon-close"></span></div></div></div>
<div class="Clear"></div>
</div>     
<div id="FileHTML" style="display:none">
<input type="hidden" name="ItemType" /> 
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">上传时间</td><td class="Input"><input type="text" name="ItemTime" readonly="readonly" style="width:150px" /></td></tr></table></div> 
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">文件名称</td><td class="Input"><input type="text" name="ItemName" class="Required" maxlength="100" style="width:521px" /></td></tr></table></div> 
<div class="Panel"><table cellpadding="0" cellspacing="0"><tr><td class="Name">外部下载</td><td class="Input"><input type="checkbox" name="ItemEnable" /></td></tr></table></div>                                                                                                                             
<div class="AIcon"><div class="Icon DownLoad"><div class="ui-state-default ui-corner-all" style="cursor:default;"><a target="_blank" style="cursor:pointer;" class="ui-icon ui-icon-arrowthickstop-1-s" onmouseover="$(this).parent().addClass('ui-state-hover');" onmouseout="$(this).parent().removeClass('ui-state-hover');"></a></div></div></div>
<div class="AIcon"><div class="Icon DeleteFile" onclick="DeleteFile(this);" title="永久删除该文件"><div class="ui-state-default ui-corner-all" onmouseover="$(this).addClass('ui-state-hover');" onmouseout="$(this).removeClass('ui-state-hover');"><span class="ui-icon ui-icon-close"></span></div></div></div>                          
<div class="Clear"></div>
</div>
<div id="ImageHTML" style="display:none">
<input type="hidden" name="AutoID" /><input type="hidden" name="FileName" /> 
<div class="Panel"><table cellpadding="0" cellspacing="0"><tbody><tr><td style="padding:4px 0 4px 4px;width:167px;height:126px;"><img width="165" height="124" style="width:165px;height:124px;border:1px solid #e5e5e5;" /></td><td valign="top">
<div><div class="IIcon Thumbnail"><div class="ui-state-default ui-corner-all" style="cursor:default;"><a target="_blank" title="下载缩略图" style="cursor:pointer;" class="ui-icon ui-icon-image" onmouseover="$(this).parent().addClass('ui-state-hover');" onmouseout="$(this).parent().removeClass('ui-state-hover');"></a></div></div></div>
<div><div class="IIcon DownLoad"><div class="ui-state-default ui-corner-all" style="cursor:default;"><a target="_blank" title="下载原始图" style="cursor:pointer;" class="ui-icon ui-icon-arrowthickstop-1-s" onmouseover="$(this).parent().addClass('ui-state-hover');" onmouseout="$(this).parent().removeClass('ui-state-hover');"></a></div></div></div>
<div><div class="IIcon Forward" onclick="Forward(this);" title="向前移动图片"><div class="ui-state-default ui-corner-all" onmouseover="$(this).addClass('ui-state-hover');" onmouseout="$(this).removeClass('ui-state-hover');"><span class="ui-icon ui-icon-seek-prev"></span></div></div></div>
<div><div class="IIcon Backward" onclick="Backward(this);" title="向后移动图片"><div class="ui-state-default ui-corner-all" onmouseover="$(this).addClass('ui-state-hover');" onmouseout="$(this).removeClass('ui-state-hover');"><span class="ui-icon ui-icon-seek-next"></span></div></div></div>
<div><div class="IIcon ToDelete" onclick="DeleteImage(this);" title="永久删除该文件"><div class="ui-state-default ui-corner-all" onmouseover="$(this).addClass('ui-state-hover');" onmouseout="$(this).removeClass('ui-state-hover');"><span class="ui-icon ui-icon-close"></span></div></div></div>
</td></tr>
<tr><td colspan="2" style="padding:0 4px 4px 4px"><input type="text" name="Summary" style="width:187px" /></td></tr>
</tbody></table></div>
<div class="Clear"></div>
</div>     
